package com.jt.demo;

import org.springframework.stereotype.Component;

@Component  //将对象交给Spring容器管理  key:Cat value:反射Cat对象
public class Cat implements Pet{
    @Override
    public void hello(){
        System.out.println("猫子叫");
    }
}
